﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Net.Sockets;
using System.Security.Cryptography.X509Certificates;
using System.Net.Security;

namespace eTerm.NetSocket
{
    public sealed class SocketPacketEventArgs : SocketAsyncEventArgs
    {
        public long PacketId { get; set; }

        public string PacketName { get; set; }

        public string PacketResult { get; set; }

        public string PacketString { get; set; }

        /// <summary>
        /// Gets or sets the e term session.
        /// </summary>
        /// <value>The e term session.</value>
        public BaseTermSocket eTermSession { get; set; }
    }

    public sealed class SslSocketCertificateValidationEventArgs : EventArgs {
        /// <summary>
        /// Gets or sets the certificate.
        /// </summary>
        /// <value>The certificate.</value>
        public X509Certificate Certificate{ get;set;}
        /// <summary>
        /// Gets or sets the chain.
        /// </summary>
        /// <value>The chain.</value>
        public X509Chain Chain{get;set;}
        /// <summary>
        /// Gets or sets the SSL policy errors.
        /// </summary>
        /// <value>The SSL policy errors.</value>
        public SslPolicyErrors SslPolicyErrors { get; set; }

        /// <summary>
        /// Gets or sets the stream.
        /// </summary>
        /// <value>The stream.</value>
        public SslStream Stream { get; set; }
    }
}
